<!DOCTYPE html>
<html lang="en" xmlns:v-on="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<script src="./node_modules/vue/dist/vue.js"></script>


<body>

<div id="vue1">
    <input type="text" v-model="name">
    <button @click="addNum">+1</button>
    <h1>{{name}}行你也行+{{num}}</h1>
</div>

<div class="vue2">
    <button v-on:click="sout">click</button>
</div>

<script>

    var app = new Vue({
        el:"#vue1",
        data:{
            name:"药水哥",
            num:0
        },
        methods:{
            addNum:function () {
                this.num++;
            }
        }
    });

    new Vue({
        el:".vue2",
        methods:{
        sout:function () {
            console.log("神奇药水...")
        }
    }

    })


</script>

</body>
</html>